/**
 * 
 */
package cw.serviceImp;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cw.entity.Group;
import cw.mapper.GroupMapper;
import cw.service.GroupService;

/**
 * @author Administrator
 *
 */
@Service("groupService")
public class GroupServiceImpl implements GroupService {

	@Resource
	private GroupMapper groupMapper;
	
	/* (non-Javadoc)
	 * @see cw.service.GroupService#deleteByPrimaryKey(java.lang.Integer)
	 */
	@Override
	public int deleteByPrimaryKey(Integer id) {
		// TODO Auto-generated method stub
		return  groupMapper.deleteByPrimaryKey(id);
	}

	/* (non-Javadoc)
	 * @see cw.service.GroupService#insert(cw.entity.Group)
	 */
	@Override
	public int insert(Group record) {
		// TODO Auto-generated method stub
		return groupMapper.insert(record);
	}

	/* (non-Javadoc)
	 * @see cw.service.GroupService#insertSelective(cw.entity.Group)
	 */
	@Override
	public int insertSelective(Group record) {
		// TODO Auto-generated method stub
		return groupMapper.insertSelective(record);
	}

	/* (non-Javadoc)
	 * @see cw.service.GroupService#selectByPrimaryKey(java.lang.Integer)
	 */
	@Override
	public Group selectByPrimaryKey(Integer id) {
		// TODO Auto-generated method stub
		return groupMapper.selectByPrimaryKey(id);
	}

	/* (non-Javadoc)
	 * @see cw.service.GroupService#updateByPrimaryKeySelective(cw.entity.Group)
	 */
	@Override
	public int updateByPrimaryKeySelective(Group record) {
		// TODO Auto-generated method stub
		return groupMapper.updateByPrimaryKeySelective(record);
	}

	/* (non-Javadoc)
	 * @see cw.service.GroupService#updateByPrimaryKey(cw.entity.Group)
	 */
	@Override
	public int updateByPrimaryKey(Group record) {
		// TODO Auto-generated method stub
		return groupMapper.updateByPrimaryKey(record);
	}

	/* (non-Javadoc)
	 * @see cw.service.GroupService#queryGroup(java.lang.String, java.lang.String, java.lang.String, java.lang.Integer, java.lang.Integer)
	 */
	@Override
	public List<Group> queryGroup(String groupName, String description,
			String id, Integer offset, Integer pageSize) {
		// TODO Auto-generated method stub
		return groupMapper.queryGroup(groupName, description, id, offset, pageSize);
	}

	/* (non-Javadoc)
	 * @see cw.service.GroupService#getTotal(java.lang.String, java.lang.String, java.lang.String)
	 */
	@Override
	public Integer getTotal(String groupName, String description, String id) {
		// TODO Auto-generated method stub
		return groupMapper.getTotal(groupName, description, id);
	}

	@Override
	public List<Group> query() {
		// TODO Auto-generated method stub
		return groupMapper.query();
	}

	@Override
	public int deleteAll() {
		// TODO Auto-generated method stub
		return groupMapper.deleteAll();
	}

}
